(************** Content-type: application/mathematica **************

                    Mathematica-Compatible Notebook

This notebook can be used with any Mathematica-compatible
application, such as Mathematica, MathReader or Publicon. The data
for the notebook starts with the line containing stars above.

To get the notebook into a Mathematica-compatible application, do
one of the following:

* Save the data starting with the line of stars above into a file
  with a name ending in .nb, then open the file inside the
  application;

* Copy the data starting with the line of stars above to the
  clipboard, then use the Paste menu command inside the application.

Data for notebooks contains only printable 7-bit ASCII and can be
sent directly in email or through ftp in text mode.  Newlines can be
CR, LF or CRLF (Unix, Macintosh or MS-DOS style).

NOTE: If you modify the data for this notebook not in a Mathematica-
compatible application, you must delete the line below containing
the word CacheID, otherwise Mathematica-compatible applications may
try to use invalid cache data.

For more information on notebooks and Mathematica-compatible 
applications, contact Wolfram Research:
  web: http://www.wolfram.com
  email: info@wolfram.com
  phone: +1-217-398-0700 (U.S.)

Notebook reader applications are available free of charge from 
Wolfram Research.
*******************************************************************)

(*CacheID: 232*)


(*NotebookFileLineBreakTest
NotebookFileLineBreakTest*)
(*NotebookOptionsPosition[      8746,        322]*)
(*NotebookOutlinePosition[      9444,        346]*)
(*  CellTagsIndexPosition[      9400,        342]*)
(*WindowFrame->Normal*)



Notebook[{
Cell[TextData[{
  "A Very Brief Review of \nDifferential Calculus\nusing ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  " "
}], "Title",
  TextAlignment->Center],

Cell[CellGroupData[{

Cell["Introduction", "Section"],

Cell[TextData[{
  "Every indented ",
  StyleBox["bold",
    FontWeight->"Bold"],
  " typed line is a valid ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  " command. You may click the mouse anywhere on one of these lines and press \
\"Enter\" on the numeric keypad to see the result generated by ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  ". For example, select the following line and press \"Enter\"."
}], "Text"],

Cell[BoxData[
    \(\(100!\)\)], "Input"],

Cell["\<\
This is 100 factorial, a pretty big number. As you read the notebooks \
throughout the semester, you should evaluate each line in order, since later \
calculations may need the results from previous results.\
\>", "Text"]
}, Closed]],

Cell[CellGroupData[{

Cell["Defining Functions", "Section"],

Cell[TextData[{
  "In ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  ",  we define functions using a few simple rules. For example,to define the \
function, ",
  Cell[BoxData[
      \(TraditionalForm\`f(x)\  = \ 2  x\^3 + \ 3  x\^2 - 12  x\  + \ 4\)]],
  ",  we enter the following code:"
}], "Text"],

Cell[BoxData[
    \(f[x_]\  := \ 2*x^3\  + \ 3*x^2\  - \ 12*x\  + \ 4\)], "Input"],

Cell[TextData[{
  "Note the use of brackets to group the argument and the use of the symbols \
\":=\" to indicate \"set equal to\". Also, don't forget the underscore \"_\" \
after the argument ",
  Cell[BoxData[
      \(TraditionalForm\`x\)]],
  ". We can now evaluate this function exactly as we have always done."
}], "Text"],

Cell[BoxData[
    \(f[2]\)], "Input"],

Cell[BoxData[
    \(f[s]\)], "Input"]
}, Closed]],

Cell[CellGroupData[{

Cell["Plotting", "Section"],

Cell[TextData[{
  "Plotting is very easy in ",
  StyleBox["Mathematica. ",
    FontSlant->"Italic"],
  StyleBox["Simply specify the function(s) and the interval over which the \
graph is to be generated. For example,  to plot ",
    FontVariations->{"CompatibilityType"->0}],
  Cell[BoxData[
      \(TraditionalForm\`f(x)\)]],
  Cell[BoxData[
      FormBox[Cell[""], TraditionalForm]]],
  " ",
  StyleBox["from -4 to 3, enter",
    FontVariations->{"CompatibilityType"->0}]
}], "Text"],

Cell[BoxData[
    \(Plot[f[x], {x, \(-4\), 3}]\)], "Input"],

Cell["\<\
This graph seems to indicate that there is a relative maximum near x = -2 and \
a relative minimum near x = 1.\
\>", "Text"]
}, Closed]],

Cell[CellGroupData[{

Cell["Differentiation", "Section"],

Cell["\<\
We will now differentiate this function three different ways. First, we will \
use the definition.\
\>", "Text"],

Cell[BoxData[
    \(Limit[\((f[x + h]\  - \ f[x])\)/h, h\  \[Rule] \ 0]\)], "Input"],

Cell[TextData[{
  "Second, we will use ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  " 's partial derivative operation, named ",
  StyleBox["D",
    FontWeight->"Bold"],
  ". Here, you can read this line as \"differentiate ",
  Cell[BoxData[
      \(TraditionalForm\`f(x)\)]],
  " with respect to ",
  Cell[BoxData[
      \(TraditionalForm\`x\)]],
  "\"."
}], "Text"],

Cell[BoxData[
    \(D[f[x], x]\)], "Input"],

Cell["\<\
Equivalently, we can use the apostrophe just like we do in written \
mathematics.\
\>", "Text"],

Cell[BoxData[
    \(\(f'\)[x]\)], "Input"]
}, Closed]],

Cell[CellGroupData[{

Cell["Critical Values", "Section"],

Cell[TextData[{
  "The critical values of a function of one variable are defined to be the \
set of values of ",
  Cell[BoxData[
      \(TraditionalForm\`x\)]],
  " for which ",
  Cell[BoxData[
      \(TraditionalForm\`f' \((x)\)\  = \ 0\)]],
  ". We first use ",
  StyleBox["Plot ",
    FontWeight->"Bold"],
  StyleBox["to give us a graphical solution.",
    FontVariations->{"CompatibilityType"->0}]
}], "Text"],

Cell[BoxData[
    \(Plot[\(f'\)[x], {x, \(-4\), 3}]\)], "Input"],

Cell[TextData[{
  "The exact solution is easy to express in ",
  StyleBox["Mathematica,  ",
    FontSlant->"Italic"],
  StyleBox["where equations are written using two equal signs.",
    FontVariations->{"CompatibilityType"->0}]
}], "Text"],

Cell[BoxData[
    \(Solve[\(f'\)[x]\  \[Equal] \ 0, x]\)], "Input"],

Cell[TextData[{
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  " 's ",
  StyleBox["Solve",
    FontWeight->"Bold"],
  " command returns its results as rules. These rules are handy when you wish \
to use substitution \"/.\" to check the result. For example, rather than just \
",
  StyleBox["Solve ",
    FontWeight->"Bold"],
  StyleBox["for ",
    FontVariations->{"CompatibilityType"->0}],
  Cell[BoxData[
      \(TraditionalForm\`x\)]],
  StyleBox[", I will save the solution as my variable \"sol\" and use it to \
check the solutions.",
    FontVariations->{"CompatibilityType"->0}]
}], "Text"],

Cell[BoxData[
    \(sol\  = Solve[\(f'\)[x]\  \[Equal] \ 0, x]\)], "Input"],

Cell[BoxData[
    \(Simplify[\(f'\)[x] \[Equal] 0 /. sol]\)], "Input"],

Cell["\<\
We now know that there are two critical values, one at x = -2 and the other \
on at x = 1.\
\>", "Text"]
}, Closed]],

Cell[CellGroupData[{

Cell["The Nature of a Function at a Critical Value", "Section"],

Cell[TextData[{
  StyleBox["Theorem:",
    FontSlant->"Italic"],
  " \nSuppose that ",
  Cell[BoxData[
      \(TraditionalForm\`x\_0\)]],
  " is a critical value for the function ",
  Cell[BoxData[
      \(TraditionalForm\`f\)]],
  ".\nA differentiable function f has a relative maximum at ",
  Cell[BoxData[
      \(TraditionalForm\`x\_0\)]],
  " if ",
  Cell[BoxData[
      \(TraditionalForm\`\(\(f''\) \((x\_0)\)\(\ \)\)\)]],
  "< 0.\nA differentiable function f has a relative minimum at ",
  Cell[BoxData[
      \(TraditionalForm\`x\_0\)]],
  " if ",
  Cell[BoxData[
      \(TraditionalForm\`\(\(f''\) \((x\_0)\)\(\ \)\)\)]],
  "> 0.\nIf ",
  Cell[BoxData[
      \(TraditionalForm\`\(\(f''\) \((x\_0)\)\(\ \)\)\)]],
  "= 0, then we must look further. In particular, ",
  Cell[BoxData[
      \(TraditionalForm\`f\)]],
  " may undergo an inflection here or we may have no conclusive information."
}], "Text",
  Background->RGBColor[0.996109, 0.996109, 0.500008]],

Cell["\<\
Using substitution again, we attempt to classify these critical values.\
\>", "Text"],

Cell[BoxData[
    \(sol\)], "Input"],

Cell[BoxData[
    \(Simplify[\(f''\)[x]\  /. \ sol]\)], "Input"],

Cell["\<\
We see that there is a relative maximum at x = -2 and a relative minimum at x \
= 2. These exact results are consistent with our graphical clues earlier.\
\>", "Text"]
}, Closed]],

Cell[CellGroupData[{

Cell["Exercise", "Section"],

Cell[TextData[{
  "Follow the above script and use ",
  StyleBox["Mathematica",
    FontSlant->"Italic"],
  "  to analyze completely the function"
}], "Text"],

Cell[BoxData[
    \(TraditionalForm\`\(\(\t\t\t\)\(f(x)\  = \ 
      x\^4\  + \ 2  x\^3\  - \ 2  x\^2\  - \ 6  x\  - \ 12\)\)\)], "Text",
  TextAlignment->Center]
}, Closed]]
},
FrontEndVersion->"4.1 for Microsoft Windows",
ScreenRectangle->{{0, 800}, {0, 527}},
WindowSize->{502, 501},
WindowMargins->{{110, Automatic}, {0, Automatic}},
Magnification->1,
StyleDefinitions -> "Classroom.nb"
]

(*******************************************************************
Cached data follows.  If you edit this Notebook file directly, not
using Mathematica, you must remove the line containing CacheID at
the top of  the file.  The cache data will then be recreated when
you save this file from within Mathematica.
*******************************************************************)

(*CellTagsOutline
CellTagsIndex->{}
*)

(*CellTagsIndex
CellTagsIndex->{}
*)

(*NotebookFileOutline
Notebook[{
Cell[1705, 50, 171, 6, 170, "Title"],

Cell[CellGroupData[{
Cell[1901, 60, 31, 0, 62, "Section"],
Cell[1935, 62, 437, 12, 48, "Text"],
Cell[2375, 76, 41, 1, 50, "Input"],
Cell[2419, 79, 231, 4, 48, "Text"]
}, Closed]],

Cell[CellGroupData[{
Cell[2687, 88, 37, 0, 42, "Section"],
Cell[2727, 90, 310, 9, 48, "Text"],
Cell[3040, 101, 82, 1, 50, "Input"],
Cell[3125, 104, 327, 7, 67, "Text"],
Cell[3455, 113, 37, 1, 50, "Input"],
Cell[3495, 116, 37, 1, 50, "Input"]
}, Closed]],

Cell[CellGroupData[{
Cell[3569, 122, 27, 0, 42, "Section"],
Cell[3599, 124, 485, 14, 48, "Text"],
Cell[4087, 140, 59, 1, 50, "Input"],
Cell[4149, 143, 134, 3, 48, "Text"]
}, Closed]],

Cell[CellGroupData[{
Cell[4320, 151, 34, 0, 42, "Section"],
Cell[4357, 153, 122, 3, 29, "Text"],
Cell[4482, 158, 84, 1, 50, "Input"],
Cell[4569, 161, 378, 14, 48, "Text"],
Cell[4950, 177, 43, 1, 50, "Input"],
Cell[4996, 180, 105, 3, 29, "Text"],
Cell[5104, 185, 42, 1, 50, "Input"]
}, Closed]],

Cell[CellGroupData[{
Cell[5183, 191, 34, 0, 42, "Section"],
Cell[5220, 193, 413, 13, 48, "Text"],
Cell[5636, 208, 64, 1, 50, "Input"],
Cell[5703, 211, 240, 6, 48, "Text"],
Cell[5946, 219, 67, 1, 50, "Input"],
Cell[6016, 222, 604, 18, 67, "Text"],
Cell[6623, 242, 75, 1, 50, "Input"],
Cell[6701, 245, 70, 1, 50, "Input"],
Cell[6774, 248, 114, 3, 44, "Text"]
}, Closed]],

Cell[CellGroupData[{
Cell[6925, 256, 63, 0, 42, "Section"],
Cell[6991, 258, 965, 29, 188, "Text"],
Cell[7959, 289, 95, 2, 29, "Text"],
Cell[8057, 293, 36, 1, 50, "Input"],
Cell[8096, 296, 64, 1, 50, "Input"],
Cell[8163, 299, 177, 3, 61, "Text"]
}, Closed]],

Cell[CellGroupData[{
Cell[8377, 307, 27, 0, 42, "Section"],
Cell[8407, 309, 158, 5, 29, "Text"],
Cell[8568, 316, 162, 3, 28, "Text"]
}, Closed]]
}
]
*)



(*******************************************************************
End of Mathematica Notebook file.
*******************************************************************)

